package com.zretc.aop;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;

/**
 * 2-> SendMessage 类 RealSubject,相当于MovieStar
 * @author Administrator
 *
 */
@Component
public class SendMessage implements ISendMessage {

	@Value("硕董")
	private String name;

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	@Override
	public void sendMessage() {
		try {
			Thread.sleep(5000);
		} catch (InterruptedException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
		System.out.println("王鑫" + name + "说: 约不约!");

	}

}
